//src/Counter.vue
<template>
<div id="counter">
  Counter: {{ counter }}
</div>
</template>


<script lang="ts">
import { defineComponent, ref } from "vue"

export default defineComponent({
    name: 'Counter',
    setup() {
      const counter = ref(0)
      counter.value = 2
      return {
        counter: counter.value
      }
    }
})
</script>